<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
</head>
<body>

    <video id="IVideo">
         <source src="movie.ogg">
    </video>
    <hr>
    <button id="switch">放大</button>

    <script>
        let IVideo = document.getElementById('IVideo');

        document.getElementById('switch').onclick =function () {

            if(document.getElementById('switch').textContent =="放大") {
                IVideo.width =500;
                document.getElementById('switch').textContent = "缩小"
            } else  {
                IVideo.width =50;
                document.getElementById('switch').textContent = "放大"
            }

        }

    </script>

</body>
</html>